<?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Home extends MY_Controller {

	function __construct(){
		parent::__construct();
		
	}	
	
	function VerifToken(){
		return true;
	}
	
	//首页入口菜单
	public function get_menu(){
		$this->load->model('Index/HomeMenuModel','menu');		
		$res = $this->menu->get_lists();
		
		foreach($res as $k=>$v){
			//$res[$k]['theme_img'] = base_url().$v['theme_img'];
		}
		/*$num = array(
			array(
				"name"  => "appoint",
				"title" => "我的预约",
				"theme_img" => base_url()."images/home_img/home-01.png",
			),
			array(
				"name"  => "train",
				"title" => "我的训练",
				"theme_img" => base_url()."images/home_img/home-02.png",
			),
			array(
				"name"  => "diets",
				"title" => "我的饮食",
				"theme_img" => base_url()."images/home_img/home-03.png",
			),
			array(
				"name"  => "article",
				"title" => "文章列表",
				"theme_img" => base_url()."images/home_img/home-04.png",
			),
			array(
				"name"  => "course",
				"title" => "课程训练",
				"theme_img" => base_url()."images/home_img/home-05.png",
			)
		);*/
		
		$data['result_code'] = 0;
		$data['message']     = '获取成功';
		$data['data'] 		 = $res;	
		$this->out($data);
	}
	
	
}
